package com.atguigu.gulimall.order.annotation;


import java.lang.annotation.*;

/**
 * @Description
 * @Author lhj
 * @Date 2024/5/23 22:01
 */
@Retention(RetentionPolicy.RUNTIME)
@Target({ElementType.ANNOTATION_TYPE, ElementType.METHOD})
@Documented
public @interface RateLimiter {
    
    String key() default "";
    
    int permitsPerSeconds() default 2;
    
    int expire() default 5;
    
    String message() default "访问过于频繁，请稍后再试";
    
    boolean isOpen() default true;
}
